package com.ygqh.baby.model;

import com.ygqh.baby.ao.PromotionType;

import java.math.BigDecimal;

public class SaveOrderBySkuDetailParam {
    private Long skuId;

    private Long quantity;

    private BigDecimal salePrice;

    private BigDecimal costPrice;

    private PromotionType promotionType;


    public SaveOrderBySkuDetailParam(Long skuId, Long quantity, BigDecimal salePrice, BigDecimal costPrice, PromotionType promotionType) {
        this.skuId = skuId;
        this.quantity = quantity;
        this.salePrice = salePrice;
        this.costPrice = costPrice;
        this.promotionType = promotionType;
    }

    public BigDecimal getRealPrice(){
        return salePrice.multiply(new BigDecimal(quantity));
    }

    public Long getSkuId() {
        return skuId;
    }

    public void setSkuId(Long skuId) {
        this.skuId = skuId;
    }

    public Long getQuantity() {
        return quantity;
    }

    public void setQuantity(Long quantity) {
        this.quantity = quantity;
    }

    public BigDecimal getSalePrice() {
        return salePrice;
    }

    public void setSalePrice(BigDecimal salePrice) {
        this.salePrice = salePrice;
    }

    public BigDecimal getCostPrice() {
        return costPrice;
    }

    public void setCostPrice(BigDecimal costPrice) {
        this.costPrice = costPrice;
    }

    public PromotionType getPromotionType() {
        return promotionType;
    }

    public void setPromotionType(PromotionType promotionType) {
        this.promotionType = promotionType;
    }
}
